home *** CD-ROM | disk | FTP | other *** search
/ InterCD 2000 February / february_2000.iso / site building / GoLive 4.0 Tryout / data1.cab / Apps / Modules / JScripts / Actions / Multimedia / Wipe Transition.action < prev    next >
Encoding:
Text File  |  1999-08-05  |  8.9 KB  |  216 lines

  1. <html>
  2.  
  3.     <head>
  4.         <meta http-equiv="content-type" content="text/html;charset=iso-8859-1">
  5.         <meta name="generator" content="Adobe GoLive 4">
  6.         <title>Wipe Transition Action</title>
  7.     </head>
  8.  
  9.     <body bgcolor="white">
  10.         <center>
  11.             <font size="6">Wipe Transition Action</font><font>
  12.             <hr>
  13.             </font></center>
  14.         <p><font>
  15.         <csactionclass name="Wipe Transition" function="CSStartWipe" nsversion="4" ieversion="4"> </font></p>
  16.         <p><font>
  17.         <csactionparam name="layer" type="GLActionLayerParam"> </font></p>
  18.         <p>
  19.         <csactionparam name="steps" type="GLActionNumParam"></p>
  20.         <p><font>
  21.         <csactionparam name="mode" type="GLActionEnumParam"> </font></p>
  22.         <p><font>
  23.         <csactionenum name="Wipe In From Left To Right" value='"_inRight"'>
  24.          </font></p>
  25.         <p><font>
  26.         <csactionenum name="Wipe In From Right To Left" value='"_inLeft"'>
  27.          </font></p>
  28.         <p><font>
  29.         <csactionenum name="Wipe In From Top To Bottom" value='"_inBottom"'>
  30.          </font></p>
  31.         <p><font>
  32.         <csactionenum name="Wipe In From Bottom To Top" value='"_inTop"'>
  33.         </font></p>
  34.         <p><font>
  35.         <csactionenum name="Wipe Out From Left To Right" value='"_outRight"'>
  36.          </font></p>
  37.         <p><font>
  38.         <csactionenum name="Wipe Out From Right To Left" value='"_outLeft"'>
  39.          </font></p>
  40.         <p><font>
  41.         <csactionenum name="Wipe Out From Top To Bottom" value='"_outBottom"'>
  42.          </font></p>
  43.         <p><font>
  44.         <csactionenum name="Wipe Out From Bottom To Top" value='"_outTop"'>
  45.         </font></p>
  46.         <p><font>
  47.         <csactionenum name="Wipe Center In" value='"_inCenter"'>
  48.         </font></p>
  49.         <p><font>
  50.         <csactionenum name="Wipe Center Out" value='"_outCenter"'>
  51.         </font></p>
  52.         <p><font></csactionparam>
  53.          </font></p>
  54.         <p><font></csactionclass>
  55.          </font></p>
  56.         <p>
  57.         <hr>
  58.         </p>
  59.         <p>IE Functions Script
  60.         <script language="JavaScript1.2" src="../../GlobalScripts/IE.scpt" cyberversion="N1.2"></script>
  61.         </p>
  62.         <p>MainLoop Functions Script
  63.         <script language="JavaScript1.2" src="../../GlobalScripts/MainLoop.scpt"></script>
  64.         </p>
  65.         <p>StyleVis Functions Script
  66.         <script language="JavaScript1.2" src="../../GlobalScripts/StyleVis.scpt" cyberversion="N1.2"></script>
  67.         </p>
  68.         <p>SytleTrans Functions Script
  69.         <script language="JavaScript1.2" src="../../GlobalScripts/StyleTrans.scpt"></script>
  70.         </p>
  71.         <p>Wipe Transition Script<font>
  72.         <script language="JavaScript1.2" cyberversion="N1.2"><!--
  73. function CSStartWipe (action)
  74. {
  75.     var el=CSCreateTransElement (action[1], action[2]);
  76.     if (el==null) return;
  77.     var dir=action[3];
  78.     if (dir=="_inLeft") {el.steps=el.clipRect.width/el.maxValue; el.modus="in";}
  79.     else if (dir=="_inRight") {el.steps=el.clipRect.width/el.maxValue; el.modus="in";}
  80.     else if (dir=="_outLeft") {el.steps=el.clipRect.width/el.maxValue; el.modus="out";}
  81.     else if (dir=="_outRight") {el.steps=el.clipRect.width/el.maxValue; el.modus="out";}
  82.     else if (dir=="_inTop") {el.steps=el.clipRect.height/el.maxValue; el.modus="in";}
  83.     else if (dir=="_inBottom") {el.steps=el.clipRect.height/el.maxValue; el.modus="in";}
  84.     else if (dir=="_outTop") {el.steps=el.clipRect.height/el.maxValue; el.modus="out";}
  85.     else if (dir=="_outBottom") {el.steps=el.clipRect.height/el.maxValue; el.modus="out";}
  86.     else if (dir=="_inCenter") {el.HSteps=el.clipRect.width/el.maxValue; el.VSteps=el.clipRect.height/el.maxValue; el.modus="in";}
  87.     else if (dir=="_outCenter") {el.HSteps=el.clipRect.width/el.maxValue; el.VSteps=el.clipRect.height/el.maxValue; el.modus="out";}
  88.     if (el.modus=="") return;
  89.     el.currentValue=0;
  90.     el.dir=action[3];
  91.     CSStartFunction(CSDoWipe,el);
  92. }
  93. function CSDoWipe (info)
  94. {
  95.     var el = info.data;
  96.     if (el==null) return false;
  97.     if (el.currentValue==el.maxValue) { CSFinishWipe(el); return false; }
  98.     var r = new CSRect(el.clipRect.left,el.clipRect.top,el.clipRect.width,el.clipRect.height);
  99.     var dir=el.dir;
  100.     if (dir=="_inLeft") {r.left=r.width-el.currentValue*el.steps;}
  101.     else if (dir=="_inTop") {r.top=r.height-el.currentValue*el.steps;}
  102.     else if (dir=="_inRight") {r.width=el.currentValue*el.steps;}
  103.     else if (dir=="_inBottom") {r.height=el.currentValue*el.steps;}
  104.     else if (dir=="_outLeft") {r.width=r.width-el.currentValue*el.steps;}
  105.     else if (dir=="_outTop") {r.height=r.height-el.currentValue*el.steps;}
  106.     else if (dir=="_outRight") {r.left=el.currentValue*el.steps;}
  107.     else if (dir=="_outBottom") {r.top=el.currentValue*el.steps;}
  108.     else if (dir=="_inCenter") {r=CSCenterRectIn(el,r);}
  109.     else if (dir=="_outCenter") {r=CSCenterRectOut(el,r);}
  110.     CSSetLayerClip(el,r);
  111.     el.currentValue+=1;
  112.     return true;
  113. }
  114. function CSFinishWipe (el)
  115. {
  116.     if (el.modus=="in") CSSetLayerClip(el,el.clipRect);
  117.     else { 
  118.         el.clipRect=new CSRect(0,0,el.width,el.height); 
  119.         CSSetLayerClip(el,el.clipRect); 
  120.         CSSetStyleVis(el.layer,0);
  121.     }
  122.     CSDisposeTransElement(el);
  123. }
  124. function CSCenterRectIn(el,r)
  125. {
  126.     var hValue= el.currentValue*el.HSteps/2;
  127.     var vValue= el.currentValue*el.VSteps/2;
  128.     r.left=Math.round(r.left+r.width/2-hValue); 
  129.     r.top=Math.round(r.top+r.height/2-vValue); 
  130.     r.width=Math.round(hValue*2);
  131.     r.height=Math.round(vValue*2);
  132.     return r;
  133. }
  134. function CSCenterRectOut(el,r)
  135. {
  136.     var hValue= el.currentValue*el.HSteps/2;
  137.     var vValue= el.currentValue*el.VSteps/2;
  138.     r.left+=Math.round(hValue); 
  139.     r.top+=Math.round(vValue); 
  140.     r.width-=Math.round(hValue*2);
  141.     r.height-=Math.round(vValue*2);
  142.     return r;
  143. }
  144. // -->
  145.         </script>
  146.         </font></p>
  147.         <p>
  148.         <hr>
  149.         </p>
  150.         <p> </p>
  151.         <p><font>
  152.         <table cool width="253" height="153" border="0" cellpadding="0" cellspacing="0" gridx="16" showgridx gridy="16" showgridy bgcolor="#eeeeee">
  153.             <tr height="1" cntrlrow>
  154.                 <td width="1" height="1"><spacer type="block" width="1" height="1"></td>
  155.                 <td width="10" height="1"><spacer type="block" width="10" height="1"></td>
  156.                 <td width="80" height="1"><spacer type="block" width="80" height="1"></td>
  157.                 <td width="160" height="1"><spacer type="block" width="160" height="1"></td>
  158.             </tr>
  159.             <tr height="2">
  160.                 <td width="1" height="2"><spacer type="block" width="1" height="2"></td>
  161.                 <td width="10" height="2"><spacer type="block" width="10" height="2"></td>
  162.                 <td width="80" height="2"><spacer type="block" width="80" height="2"></td>
  163.                 <td width="160" height="2"><spacer type="block" width="160" height="2"></td>
  164.             </tr>
  165.             <tr height="3">
  166.                 <td width="1" height="3"><spacer type="block" width="1" height="3"></td>
  167.                 <td width="10" height="3"><spacer type="block" width="10" height="3"></td>
  168.                 <td width="80" height="3"><spacer type="block" width="80" height="3"></td>
  169.                 <td width="160" height="26" colspan="1" rowspan="2" valign="top" align="left" xpos="90">
  170.                     <csactioncntrl name="layer" x="90" y="2" width="140" height="18" alignx="scale" aligny="top">
  171.                 </td>
  172.             </tr>
  173.             <tr height="23">
  174.                 <td width="1" height="23"><spacer type="block" width="1" height="23"></td>
  175.                 <td width="10" height="23"><spacer type="block" width="10" height="23"></td>
  176.                 <td width="80" height="23" colspan="1" rowspan="1" valign="top" align="left" xpos="10">
  177.                     <csactioncntrl type="StaticText" value="Floating Box" x="10" y="5" width="70" height="17" alignx="left" aligny="top">
  178.                 </td>
  179.             </tr>
  180.             <tr height="3">
  181.                 <td width="1" height="3"><spacer type="block" width="1" height="3"></td>
  182.                 <td width="10" height="3"><spacer type="block" width="10" height="3"></td>
  183.                 <td width="80" height="3"><spacer type="block" width="80" height="3"></td>
  184.                 <td width="160" height="27" colspan="1" rowspan="2" valign="top" align="left" xpos="90">
  185.                     <csactioncntrl name="mode" x="90" y="28" width="140" height="18" alignx="scale" aligny="top">
  186.                 </td>
  187.             </tr>
  188.             <tr height="24">
  189.                 <td width="1" height="24"><spacer type="block" width="1" height="24"></td>
  190.                 <td width="10" height="24"><spacer type="block" width="10" height="24"></td>
  191.                 <td width="80" height="24" colspan="1" rowspan="1" valign="top" align="left" xpos="10">
  192.                     <csactioncntrl type="StaticText" value="Transition" x="10" y="31" width="72" height="16" alignx="left" aligny="top">
  193.                 </td>
  194.             </tr>
  195.             <tr height="3">
  196.                 <td width="1" height="3"><spacer type="block" width="1" height="3"></td>
  197.                 <td width="10" height="3"><spacer type="block" width="10" height="3"></td>
  198.                 <td width="80" height="3"><spacer type="block" width="80" height="3"></td>
  199.                 <td width="160" height="95" colspan="1" rowspan="2" valign="top" align="left" xpos="90">
  200.                     <csactioncntrl name="steps" x="90" y="55" width="63" height="18" alignx="left" aligny="top">
  201.                 </td>
  202.             </tr>
  203.             <tr height="92">
  204.                 <td width="1" height="92"><spacer type="block" width="1" height="92"></td>
  205.                 <td width="10" height="92"><spacer type="block" width="10" height="92"></td>
  206.                 <td width="80" height="92" colspan="1" rowspan="1" valign="top" align="left" xpos="10">
  207.                     <csactioncntrl type="StaticText" value="Steps" x="10" y="58" width="35" height="16" alignx="left" aligny="top">
  208.                 </td>
  209.             </tr>
  210.         </table>
  211.         </font></p>
  212.         <p> 
  213.     </body>
  214.  
  215. </html>
  216.